
import React, { Component } from 'react';
import {Link,Route} from "react-router-dom";
import Dept from "./Dept";
import User from "./User"

export default class index extends Component {
  render() {
    return (
      <div>
        <h1>二级路由示例</h1>
        <Link to="/SecondRoute/Dept">部门管理</Link>&nbsp;&nbsp;|&nbsp;&nbsp;
        <Link to="/SecondRoute/User">用户管理</Link>&nbsp;&nbsp;|&nbsp;&nbsp;
        <hr/>
        <Route path="/SecondRoute/Dept" component={Dept}></Route>
        <Route path="/SecondRoute/User" component={User}></Route>
      </div>
    )
  }
}
